package com.unicom.office.node;

import com.unicom.office.func.FuncCommon;
import com.unicom.office.type.CellTypeItem;
import com.unicom.office.type.RowTypeItem;
import com.unicom.office.type.TypeItem;
import com.unicom.office.func.FuncBase;
import com.unicom.office.unit.OfficeUnit;
import com.unicom.office.unit.RowUnit;

public class RowNode extends OfficeNode {
    public RowNode(Object source) {
        super(source);
    }

    public OfficeUnit createUnit() {
        return new RowUnit();
    }

    public boolean testChildType(FuncCommon child) {
        return child.getType() == CellTypeItem.INSTANCE;
    }

    public OfficeNodeType getNodeType() {
        return OfficeNodeType.Row;
    }

    public TypeItem getType() {
        return RowTypeItem.INSTANCE;
    }
}
